package org.jsola.hr.web;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.jsola.core.Page;
import org.jsola.core.Result;
import org.jsola.hr.dto.MissionCenterFeedBackDTO;
import org.jsola.hr.dto.MissionCenterItemAddDTO;
import org.jsola.hr.dto.MissionCenterItemUpdateDTO;
import org.jsola.hr.query.MissionCenterItemQuery;
import org.jsola.hr.vo.MissionCenterItemListVO;
import org.jsola.hr.vo.MissionCenterItemVO;
import org.springframework.core.io.Resource;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.RequestParam;

import javax.validation.Valid;
import java.util.List;

/**
 * 任务调度中心任务子项表
 *
 * @author zhr
 */
@Api(tags = "hr-任务调度中心任务子项表")
public interface IMissionCenterItemControllerAPI {

    /**
     * 新增任务调度中心任务子项表
     *
     * @param missionCenterItemAddDTO 任务调度中心任务子项表新增实体
     * @return 任务调度中心任务子项表展示对象
     */
    @ApiOperation(value = "新增任务调度中心任务子项表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemAddDTO", dataType = "MissionCenterItemAddDTO", value = "新增任务调度中心任务子项表", paramType = "body")
    })
    Result<MissionCenterItemVO> save(MissionCenterItemAddDTO missionCenterItemAddDTO);


    /**
     * 修改任务调度中心任务子项表
     *
     * @param missionCenterItemUpdateDTO 任务调度中心任务子项表
     * @return 更新数量
     */
    @ApiOperation(value = "修改任务调度中心任务子项表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemUpdateDTO", dataType = "MissionCenterItemUpdateDTO", value = "修改任务调度中心任务子项表", paramType = "body")
    })
    Result<Integer> update(MissionCenterItemUpdateDTO missionCenterItemUpdateDTO);


    /**
     * 删除单个任务调度中心任务子项表，彻底删除
     *
     * @param missionCenterItemId 任务调度中心任务子项表id
     * @return 删除数量
     */
    @ApiOperation(value = "删除单个任务调度中心任务子项表，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemId", dataType = "String", value = "任务调度中心任务子项表id", paramType = "path")
    })
    Result<Integer> delete(String missionCenterItemId);


    /**
     * 批量删除任务调度中心任务子项表，彻底删除
     *
     * @param missionCenterItemIds 任务调度中心任务子项表id集合
     * @return 删除数量
     */
    @ApiOperation(value = "批量删除任务调度中心任务子项表，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemIds", dataType = "String[]", value = "任务调度中心任务子项表id数组", paramType = "body", allowMultiple = true)
    })
    Result<Integer> deleteBatch(String[] missionCenterItemIds);


    /**
     * 根据任务调度中心任务子项表id查询任务调度中心任务子项表详情
     *
     * @param missionCenterItemId 任务调度中心任务子项表id
     * @return 任务调度中心任务子项表详情
     */
    @ApiOperation(value = "根据任务调度中心任务子项表id查询任务调度中心任务子项表详情")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemId", dataType = "String", value = "任务调度中心任务子项表id", paramType = "path")
    })
    Result<MissionCenterItemVO> findById(String missionCenterItemId);


    /**
     * 查询任务调度中心任务子项表
     *
     * @param missionCenterItemQuery 任务调度中心任务子项表查询参数
     * @return page
     */
    @ApiOperation(value = "查询任务调度中心任务子项表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemQuery", dataType = "MissionCenterItemQuery", value = "任务调度中心任务子项表查询参数", paramType = "query")
    })
    Result<List<MissionCenterItemListVO>> listAll(MissionCenterItemQuery missionCenterItemQuery);


    /**
     * 分页查询任务调度中心任务子项表
     *
     * @param missionCenterItemQuery 任务调度中心任务子项表查询参数
     * @return page
     */
    @ApiOperation(value = "分页查询任务调度中心任务子项表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemQuery", dataType = "MissionCenterItemQuery", value = "任务调度中心任务子项表查询参数", paramType = "query")
    })
    Result<Page<MissionCenterItemListVO>> page(MissionCenterItemQuery missionCenterItemQuery);

    /**
     * 查询任务子项明细
     *
     * @param missionCenterItemQuery 查询参数
     * @return 子项列表
     */
    @ApiOperation(value = "查询任务子项明细")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemQuery", dataType = "MissionCenterItemQuery", value = "查询参数", paramType = "query")
    })
    Result<Page<MissionCenterItemListVO>> selectMissionCenterItem(@Valid MissionCenterItemQuery missionCenterItemQuery);

    /**
     * 反馈
     *
     * @param missionCenterFeedBackDTO 反馈参数
     * @return 反馈结果
     */
    @ApiOperation(value = "反馈")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterFeedBackDTO", dataType = "MissionCenterFeedBackDTO", value = "反馈子项参数", paramType = "body")
    })
    Result<Integer> feedback(MissionCenterFeedBackDTO missionCenterFeedBackDTO);

    /**
     * 导出接单列表
     *
     * @param missionCenterItemQuery 导出参数
     * @return excel
     */
    @ApiOperation(value = "导出接单列表")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "missionCenterItemQuery", dataType = "MissionCenterItemQuery", value = "导出参数", paramType = "body"),
    })
    ResponseEntity<Resource> exportReceivePath(MissionCenterItemQuery missionCenterItemQuery);

}

